package com.bianmaba.spring.supports.data.repository.specification.condition.predicate.generator;

import javax.persistence.criteria.CriteriaBuilder;
import javax.persistence.criteria.Expression;
import java.lang.reflect.Method;

/**
 * 等于
 * Created by cwx183898 on 2017/12/17.
 */
public class EqPredicateGenerator extends AbstractPredicateGenerator {

    protected Method getCreateMethod(CriteriaBuilder builder) {
        Method method = null;
        try {
            method = builder.getClass().getMethod("equal", Expression.class, Object.class);
        } catch (NoSuchMethodException e) {
            e.printStackTrace();
        }
        return method;
    }
}
